<?php
include_once 'app/until/GFW_HTTP.php';
class publish{

	private $daten;
	private $User_Id;

	public function __construct($match){
		$this->daten = $match;

		if (!isset($_SESSION['UserId'])){
			HTTP::redirect ( BASE_URL . '/NotLogin' );
		}else{
			$this->User_Id = $_SESSION ['UserId'];
		}
	}

	public function getWort(RainTPL $design){
		$this->design = $design;
		$DBPublish = new Db_Publish();
		
		if($this->design->get->soWhat){
			$DBPublish->Publish($this->User_Id,$this->design->get->soWhat);
		}
		HTTP::redirect ( BASE_URL . '/');
	}

}
?>